SpreadCloseMark
SpreadCloseMark records are created immediately after the market close (clsMarkState=SRClose), when exchanges publish official marks (clsMarkState=ExchClose), and again during top of day rotation (clsMarkState=Final). These records contain closing quotes and prices as well as markup details for all exchange spreads SpreadCloseMark records are published to the SpiderRock elastic cluster when clsMarkState=Final BaseObj:Spread
METADATA
Attribute | Value |
---|---|
Topic | 3120-market-marks |
MLink Token | SpreadMktData |
Product | SRAnalytics |
accessType | SELECT |
Table Definition
Field | Type | Key | Default Value | Comment |
---|---|---|---|---|
skey_at | enum - AssetType | PRI | 'None' | |
skey_ts | enum - TickerSrc | PRI | 'None' | |
skey_tk | VARCHAR(12) | PRI | '' | |
clsMarkState | enum - ClsMarkState | 'None' | Close mark state None LastPrt SRClose ExchClose Final | |
opnPrc | DOUBLE | 0 | Open price | |
minPrc | DOUBLE | 0 | Low price | |
maxPrc | DOUBLE | 0 | High price | |
prtCount | INT | 0 | Print count | |
prtVolume | INT | 0 | Print volume | |
avgMktSize | DOUBLE | 0 | Average market size | |
avgMktWidth | DOUBLE | 0 | Average market width | |
bidPrc | DOUBLE | 0 | bid price close 1min | |
askPrc | DOUBLE | 0 | ask price close 1min | |
srClsPrc | DOUBLE | 0 | SR close mark close 1min | |
closePrc | DOUBLE | 0 | official exchange closing mark last printthen official close | |
timestamp | DATETIME(6) | '1900-01-01 00:00:00.000000' |
PRIMARY KEY DEFINITION (Unique)
Field | Sequence |
---|---|
skey_tk | 1 |
skey_at | 2 |
skey_ts | 3 |
CREATE TABLE EXAMPLE QUERY
CREATE TABLE `SRAnalytics`.`MsgSpreadCloseMark` (
`skey_at` ENUM('None','EQT','IDX','BND','CUR','COM','FUT','SYN','WAR','FLX','MUT','SPD','MM','MF','COIN','TOKEN','ANY') NOT NULL DEFAULT 'None',
`skey_ts` ENUM('None','SR','NMS','CME','ICE','CFE','CBOT','NYMEX','COMEX','RUT','CIDX','ARCA','NYSE','OTC','NSDQ','MFQS','MIAX','DJI','CUSIP','ISIN','BXE','EUX','ANY','CXE','DXE','NXAM','NXBR','NXLS','NXML','NXOS','NXP','EUREX','CEDX','ICEFE') NOT NULL DEFAULT 'None',
`skey_tk` VARCHAR(12) NOT NULL DEFAULT '',
`clsMarkState` ENUM('None','Preview','Final') NOT NULL DEFAULT 'None' COMMENT 'Close mark state. None; LastPrt; SRClose; ExchClose; Final',
`opnPrc` DOUBLE NOT NULL DEFAULT 0 COMMENT 'Open price',
`minPrc` DOUBLE NOT NULL DEFAULT 0 COMMENT 'Low price',
`maxPrc` DOUBLE NOT NULL DEFAULT 0 COMMENT 'High price',
`prtCount` INT NOT NULL DEFAULT 0 COMMENT 'Print count',
`prtVolume` INT NOT NULL DEFAULT 0 COMMENT 'Print volume',
`avgMktSize` DOUBLE NOT NULL DEFAULT 0 COMMENT 'Average market size',
`avgMktWidth` DOUBLE NOT NULL DEFAULT 0 COMMENT 'Average market width',
`bidPrc` DOUBLE NOT NULL DEFAULT 0 COMMENT 'bid price (close - 1min)',
`askPrc` DOUBLE NOT NULL DEFAULT 0 COMMENT 'ask price (close - 1min)',
`srClsPrc` DOUBLE NOT NULL DEFAULT 0 COMMENT 'SR close mark (close - 1min)',
`closePrc` DOUBLE NOT NULL DEFAULT 0 COMMENT 'official exchange closing mark (last print;then official close)',
`timestamp` DATETIME(6) NOT NULL DEFAULT '1900-01-01 00:00:00.000000',
PRIMARY KEY USING HASH (`skey_tk`,`skey_at`,`skey_ts`)
) ENGINE=SRSE DEFAULT CHARSET=LATIN1 COMMENT='SpreadCloseMark records are created immediately after the market close (clsMarkState=SRClose), when exchanges publish official marks (clsMarkState=ExchClose), and again during top of day rotation (clsMarkState=Final). These records contain closing quotes and prices as well as markup details for all exchange spreads\nSpreadCloseMark records are published to the SpiderRock elastic cluster when clsMarkState=Final\nBaseObj:Spread';
SELECT TABLE EXAMPLE QUERY
SELECT
`skey_at`,
`skey_ts`,
`skey_tk`,
`clsMarkState`,
`opnPrc`,
`minPrc`,
`maxPrc`,
`prtCount`,
`prtVolume`,
`avgMktSize`,
`avgMktWidth`,
`bidPrc`,
`askPrc`,
`srClsPrc`,
`closePrc`,
`timestamp`
FROM `SRAnalytics`.`MsgSpreadCloseMark`
WHERE
/* Replace with a ENUM('None','EQT','IDX','BND','CUR','COM','FUT','SYN','WAR','FLX','MUT','SPD','MM','MF','COIN','TOKEN','ANY') */
`skey_at` = 'None'
AND
/* Replace with a ENUM('None','SR','NMS','CME','ICE','CFE','CBOT','NYMEX','COMEX','RUT','CIDX','ARCA','NYSE','OTC','NSDQ','MFQS','MIAX','DJI','CUSIP','ISIN','BXE','EUX','ANY','CXE','DXE','NXAM','NXBR','NXLS','NXML','NXOS','NXP','EUREX','CEDX','ICEFE') */
`skey_ts` = 'None'
AND
/* Replace with a VARCHAR(12) */
`skey_tk` = 'Example_skey_tk';
Doc Columns Query
SELECT * FROM SRAnalytics.doccolumns WHERE TABLE_NAME='SpreadCloseMark' ORDER BY ordinal_position ASC;